﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

    <ControlTemplate x:Key="button"
                     TargetType="Button">
        <Grid>
            <VisualStateManager.VisualStateGroups>
                <VisualStateGroup x:Name="CommonStates">
                    <VisualState x:Name="Normal" />
                    <VisualState x:Name="MouseOver">
                        <Storyboard>
                            <ObjectAnimationUsingKeyFrames Duration="0"
                                                           Storyboard.TargetProperty="Effect"
                                                           Storyboard.TargetName="Background">
                                <DiscreteObjectKeyFrame KeyTime="0">
                                    <DiscreteObjectKeyFrame.Value>
                                        <DropShadowEffect BlurRadius="10"
                                                          Color="#FF09D1EE"
                                                          Opacity=".75"
                                                          ShadowDepth="0"
                                                          Direction="0" />
                                    </DiscreteObjectKeyFrame.Value>
                                </DiscreteObjectKeyFrame>
                            </ObjectAnimationUsingKeyFrames>
                        </Storyboard>
                    </VisualState>
                    <VisualState x:Name="Pressed">
                        <Storyboard>
                            <ObjectAnimationUsingKeyFrames Duration="0"
                                                           Storyboard.TargetProperty="Effect"
                                                           Storyboard.TargetName="Background">
                                <DiscreteObjectKeyFrame KeyTime="0">
                                    <DiscreteObjectKeyFrame.Value>
                                        <DropShadowEffect BlurRadius="10"
                                                          Color="#FF09D1EE"
                                                          Opacity=".75"
                                                          ShadowDepth="0"
                                                          Direction="0" />
                                    </DiscreteObjectKeyFrame.Value>
                                </DiscreteObjectKeyFrame>
                            </ObjectAnimationUsingKeyFrames>
                        </Storyboard>
                    </VisualState>
                    <VisualState x:Name="Disabled">
                        <Storyboard>
                            <DoubleAnimation Duration="0"
                                             To=".15"
                                             Storyboard.TargetProperty="Opacity"
                                             Storyboard.TargetName="DisabledVisualElement" />
                        </Storyboard>
                    </VisualState>
                </VisualStateGroup>
                <VisualStateGroup x:Name="FocusStates">
                    <VisualState x:Name="Focused">
                        <Storyboard>
                            <ObjectAnimationUsingKeyFrames Duration="0"
                                                           Storyboard.TargetProperty="Effect"
                                                           Storyboard.TargetName="Background">
                                <DiscreteObjectKeyFrame KeyTime="0">
                                    <DiscreteObjectKeyFrame.Value>
                                        <DropShadowEffect BlurRadius="10"
                                                          Color="#FF09D1EE"
                                                          Opacity=".75"
                                                          ShadowDepth="0"
                                                          Direction="0" />
                                    </DiscreteObjectKeyFrame.Value>
                                </DiscreteObjectKeyFrame>
                            </ObjectAnimationUsingKeyFrames>
                        </Storyboard>
                    </VisualState>
                    <VisualState x:Name="Unfocused" />
                </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <Border x:Name="Background"
                    BorderBrush="{TemplateBinding BorderBrush}"
                    BorderThickness="{TemplateBinding BorderThickness}"
                    Background="{TemplateBinding Background}"
                    CornerRadius="16"
                    MinWidth="75">
                <ContentPresenter x:Name="contentPresenter"
                                  ContentTemplate="{TemplateBinding ContentTemplate}"
                                  Content="{TemplateBinding Content}"
                                  HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                  Margin="{TemplateBinding Padding}"
                                  VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
            </Border>

            <Rectangle x:Name="DisabledVisualElement"
                       RadiusX="16"
                       RadiusY="16"
                       Fill="LightGray"
                       IsHitTestVisible="false"
                       Opacity="0" />
        </Grid>
    </ControlTemplate>

</ResourceDictionary>
